package com.google.wallet.online.jwt;

/**
 * Bean to represent the request/response body
 * 
 * @author pying
 *
 */
public class WalletBody {
  
  String googleTransactionId;
  String merchantTransactionId;
  String clientId;
  String merchantName;
  String origin;
  String email;
  Boolean phoneNumberRequired;
  Pay pay;
  Ship ship;
  

  public WalletBody(){ 
  }

  public WalletBody(String gti, String ci, String mn, String o, Pay p,
      Ship s) {
    setGoogleTransactionId(gti);
    setClientId(ci);
    setMerchantName(mn);
    setOrigin(o);
    setPay(p);
    setShip(s);
  }
  
  public WalletBody(String ci, String mn, String o){
    setClientId(ci);
    setMerchantName(mn);
    setOrigin(o);
  }
  
  public WalletBody(String ci, String mn, String o, Pay p, Ship s){
    setClientId(ci);
    setMerchantName(mn);
    setOrigin(o);
    setPay(p);
    setShip(s);
  }
  
  public String getEmail() {
    return email;
  }

  public void setEmail(String email) {
    this.email = email;
  }
  /**
   * Setter of the origin request param which is protocol://domain:port for
   * where the request was sent from
   * 
   * @param origin
   *          origin of the request
   */
  public void setOrigin(String origin) {
    this.origin = origin;
  }

  /**
   * Getter for the origin param
   * 
   * @return origin URL
   */
  public String getOrigin() {
    return origin;
  }

  /**
   * Getter for Google transaction id to track a single transaction flow through
   * multiple API calls
   * 
   * @return the Google transaction id.
   */
  public String getGoogleTransactionId() {
    return googleTransactionId;
  }

  /**
   * Setter for Google transaction id which is used to track a single
   * transaction through multiple API calls
   * 
   * @param googleTransactionId
   *          the provided Google transaction id
   */
  public void setGoogleTransactionId(String gti) {
    this.googleTransactionId = gti;
  }

  /**
   * Getter for Tranaction Id a param the merchant can use to track a single
   * transaction through multiple API calls
   * 
   * @return Transaction Id
   */
  public String getTransactionId() {
    return merchantTransactionId;
  }

  /**
   * Setter for Transaction Id a param the merchant can use to track a single
   * transaction through multiple API calls
   * 
   * @param transaction_id
   *          Transaction Id to set
   */
  public void setTransactionId(String merchantTransactionId) {
    this.merchantTransactionId = merchantTransactionId;
  }
  
  public Pay getPay() {
    return pay;
  }

  public void setPay(Pay pay) {
    this.pay = pay;
  }

  public Ship getShip() {
    return ship;
  }

  public void setShip(Ship ship) {
    this.ship = ship;
  }
  
  public String getClientId() {
    return clientId;
  }

  public void setClientId(String clientId) {
    this.clientId = clientId;
  }
  
  public String getMerchantName() {
    return merchantName;
  }

  public void setMerchantName(String merchantName) {
    this.merchantName = merchantName;
  }
  
  public Boolean getPhoneNumberRequired() {
    return phoneNumberRequired;
  }

  public void setPhoneNumberRequired(Boolean phoneNumberRequired) {
    this.phoneNumberRequired = phoneNumberRequired;
  }
}
